import fetch from "src/utils/fetch";
import API from "src/utils/api";
import notification from "src/utils/notification";

const Router = {
  state: {
    storeRouterInfo:{}
  },
  mutations: {
    UPDATE_ROUTER_INFO(state,data){
        state.storeRouterInfo = data;
    }
  },
  actions: {
    getRouterInfo:({state ,commit},params) => {
        fetch({
            url: '/config/getRouterInfo',
            type: "post",
            data: params,
            showRegionLoading: true,
            success: (data) => {
                commit("UPDATE_ROUTER_INFO", data);
            },
          });
    },
   
  },
  getters: {
    storeRouterInfo: state => state.storeRouterInfo    
  }
};

export default Router;
